package com.iias.communication.config;

import com.iias.communication.domain.ServerConfig;
import com.iias.communication.domain.ServiceInfo;
import com.iias.communication.enums.NodeLook;

import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;

/**
 * 服务注册与发现 配置
 */
public class CommunicationConfig implements Serializable {

    private static final long serialVersionUID = -6781253421357076280L;

    /**
     * 发现方式 推荐使用(master 自动发现 与 注册 )
     */
    private NodeLook nodeLook = NodeLook.MANUAL;


    private ServerConfig server = new ServerConfig();
    /**
     * 节点
     */
    private List<ServiceInfo> clients = new ArrayList<ServiceInfo>();


    public NodeLook getNodeLook() {
        return nodeLook;
    }

    public void setNodeLook(NodeLook nodeLook) {
        this.nodeLook = nodeLook;
    }

    public List<ServiceInfo> getClients() {
        return clients;
    }

    public void setClients(List<ServiceInfo> clients) {
        this.clients = clients;
    }

    public ServerConfig getServer() {
        return server;
    }

    public void setServer(ServerConfig server) {
        this.server = server;
    }
}
